<?php
    namespace app\index\validate;
    use think\Validate; //使用验证类
class Reply extends Validate {
    //先写规则
    protected $rule = [
        'gue_email' => 'email|require|max:25',
        'gue_content' => 'require|max:100',
    ];
    //违反规则提示的文本
    protected $message = [
        'gue_email.email' => '邮箱格式不正确',
        'gue_email.require' => '邮箱不能为空',
        'gue_email.max' => '邮箱长度不能超过25个字符',
        'gue_content.require' => '内容不能为空',
        'gue_content.max' => '内容长度不能超过100个字符',
    ];
}
